<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<title>德通物流|登录</title>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/style.css" rel="stylesheet">
<style type="text/css">
#error {
	font-size: 10px;
	color: #F00;
	margin-left: 4px;
	display: none;
}
</style>
</head>
<body>
	<div class="container">
		<div class="header">
			<h1>德通物流管理系统</h1>
		</div>

		<form class="form-signin">
			<h2 class="form-signin-heading">请登录</h2>
			<br /> <input type="text" id="phone" class="form-control"
				placeholder="请输入手机号" required autofocus><br /> <input
				type="password" id="password" class="form-control"
				placeholder="请输入密码" required>
			<span id="error">*用户名或密码错误</span>
			<button id="btn_sub" class="btn btn-lg btn-primary btn-block"
				style="margin-top: 10px" type="button">登&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;录</button>
		</form>
	</div>
	
	<script src="js/jquery.min.js"></script>
	<script type="text/javascript">
		$(document).ready(function() {
			$('#btn_sub').click(function() {
				$.post("/logistics/logining", {
					phone : $('#phone').val(),
					password : $('#password').val()
				}, function(data) {
					if (data == "false") {
						$('#error').css("display", "inline");
					} else {
						window.open("index", "_self");
					}
				});
			});
			$('input').focus(function() {
				$('#error').css("display", "none");
			});
		});
	</script>
</body>
</html>